package com.sugar.web.action.system;

import javax.annotation.Resource;

import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Controller;

import com.sugar.domain.system.privilege.PrivilegeResourceModel;
import com.sugar.service.system.privilege.IPrivilegeResourceModelService;
import com.sugar.web.action.base.BaseActionSupport;

@Controller
@Scope("prototype")
public class PrivilegeModelAction extends BaseActionSupport {

	private static final long serialVersionUID = 1L;

	private PrivilegeResourceModel prm ;
	
	public PrivilegeResourceModel getPrm() {
		return prm;
	}

	public void setPrm(PrivilegeResourceModel prm) {
		this.prm = prm;
	}

	@Resource
	private IPrivilegeResourceModelService priModelService ;
	
	public String queryAll() throws Exception {
		
		this.getRequest().setAttribute("privilegeModel", this.priModelService.findPRModelService(null)) ;
		
		return "querySuccess" ;
	}
	
}
